﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CoolCode.Linq;
using CoolCode.Entities;

namespace CoolCode.Services
{
    public interface IInspectionService : ITrackService<Inspection>,
        ISearchService<Inspection>, 
        ISearchService<SearchItem,Outbound >
    {
        //PaginatedList<Inspection> Paging(IQueryBuilder<Inspection> queryBuilder, PageParam p);
        //List<Inspection> List(IQueryBuilder<Inspection> queryBuilder);
        InspectionSummary ListSummaryBySpec(IQueryBuilder<Inspection> queryBuilder);
        InspectionSummary Summary(IQueryBuilder<Inspection> detail,IQueryBuilder<Inspection> group);
        int Count(IQueryBuilder<Inspection> queryBuilder);
        bool Contains(string productID);
        Inspection Get(string productID);
        void SaveInspection(Inspection entity, Log log);

        PaginatedList<Inspection> PagingOutbound(Guid guid, PageParam p);
        List<Inspection> ListOutbound(Guid guid);
        Guid Outbound(List<string> productIDList, string user, DateTime date, Log log);

        Guid Cancel(List<string> productIDList, string user, DateTime date, Log log);
        //PaginatedList<SearchItem> Paging(IQueryBuilder<Outbound> queryBuilder, PageParam p);


        List<ValueText> ListStatus(bool includeAll);

        List<string> ListExistedProductID(List<string> productIDList);
        Guid  ImportInspection(List<Inspection> list, string user, Log log);
    }
}
